FROM python:3.8-buster
LABEL maintainer="martinsun"

#上工作路径设定为/code
ARG WORK_PWD=/data/
#上工作路径设定为/code
WORKDIR $WORK_PWD
ENV TZ "Asia/Shanghai"

# 设置pip源 COPY pip.conf /etc/pip.conf
RUN mkdir ~/.pip && \
    echo "[global]" >~/.pip/pip.conf && \
    echo "index-url = https://pypi.tuna.tsinghua.edu.cn/simple" >>~/.pip/pip.conf  && \
    echo "proxy = http://xxxx.com:8080" >>~/.pip/pip.conf
#安装环境
RUN pip install selenium==3.141.0 && \
    pip install PyYAML && \
    pip install pytest && \
    pip install pytest-xdist && \
    pip install pytest-metadata && \
    pip install allure-pytest && \
    pip install xlrd && \
    pip install xlwt && \
    pip install xlutils && \
    pip install Faker && \
    pip install pystache && \
    pip install PyMySQL


STOPSIGNAL SIGTERM

##为容器设置默认启动命令
#CMD ["flask","run"]
